With increasing development of science and technology, a serial advanced technology attachment (SATA) bus is widely used as a connection bus between a storage device and a host of a computer system in order to replace the conventional integrated device electronics (IDE) bus. The storage device is for example a hard disc drive or a solid state drive.
Generally, the SATA specifications comprise a SATA 1.0 specification, a SATA 2.0 specification and a STAT 3.0 specification. The data transmission speed of the SATA 1.0 specification is 1.5 Gbit/s, the data transmission speed of the SATA 2.0 specification is 3 Gbit/s, and the data transmission speed of the SATA 3.0 specification is 6 Gbit/s. That is, with the increasing progress of the SATA specifications, the speed of transferring data between the host and the storage device is gradually increased. Moreover, the SATA 3.0 specification further supports native command queuing (NCQ) in order to achieve better performance of transferring data between the host and the storage device.
The storage device that supports the NCQ may receive plural commands from the host. Moreover, the commands are not sequentially executed by the storage device in order. On the contrary, the storage device may rearrange the sequence of executing these commands according to the types of the commands and the storage positions of the data.
According to the SATA 3.0 specification, the storage device that supports the NCQ may continuously receive 32 commands from the host and execute these commands in an out-of-order manner.
For example, if 32 read commands from the host are received by the storage device, after the sequence of the read commands are rearranged by the storage device, the read data corresponding to the read commands are transmitted back from the storage device to the host. After the execution of any read command is completed, the host may issue a new read command to the storage device again. Since 32 read commands are ready to be executed by the storage device at any time, the reading performance of the storage device is largely enhanced.
However, the current SATA 3.0 specification still has some drawbacks. For example, after the read data is transmitted back from the storage device, it is difficult for the host to transmit a new read command to the storage device. The reasons will be illustrated as follows.
According to the SATA 3.0 specification, while the host and the storage device intend to exchange data between each other simultaneously, the host has to postpone the frame transmission at first. That is, when the host and the storage device simultaneously issue a frame transmission request, the priority of the frame transmission of the storage device is higher than the priority of the frame transmission of the host. Moreover, the contents of the frame may contain read data, write data or commands.
For example, after the 32 read commands are received by the storage device, the read data corresponding to the read commands are continuously transmitted back from the storage device to the host. During the process of continuously transmitting the 32 read data from the storage device to the host, the frame transmission requests from the host are almost postponed. Consequently, after the 32 read data are completely transmitted from the storage device to the host and no read commands are ready to be executed by the storage device, the frame transmission request can be successfully issued from the host and the new read command can be successfully transmitted to the storage device.
From the above discussions, if there are no read commands to be executed by the storage device at any time, the reading performance of the storage device will be deteriorated. The transmission of the read command is presented herein for purpose of illustration and description only. It is noted that the same situations may be applied to the transmission of the write command and the write data.
For increasing the accessing performance of the storage device according to the SATA specification, it is suitable to continuously provide the read commands to be executed by the storage device.